From e8079df420e50b159ba9ba7484d04b4323251bc7 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Tue, 16 Jan 2018 14:50:25 -0500 Subject: [PATCH] mountoperation: Fix a crash We only create the gesture when the dialog is needed, so don't free it unconditionally. --- gtk/gtkmountoperation.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gtk/gtkmountoperation.c b/gtk/gtkmountoperation.c index 4be287f629..1bd74cc268 100644 --- a/gtk/gtkmountoperation.c +++ b/gtk/gtkmountoperation.c @@ -231,7 +231,8 @@ gtk_mount_operation_finalize (GObject *object) if (priv->handler) g_object_unref (priv->handler); - g_object_unref (priv->multipress_gesture); + if (priv->multipress_gesture) + g_object_unref (priv->multipress_gesture); G_OBJECT_CLASS (gtk_mount_operation_parent_class)->finalize (object); } -- 2.30.2